<%= content_tag :li, :id => dom_id(root), :class => "category" do %>
  <%= content_tag :div do %>
    <%= "#{root.presentation}" %>

    <%= hidden_field_tag :node_id, "", :value => root.id, :class => "node_id" %>

    <span style="float: right;">
      <%= button_to_delete "Smazat kategorii", admin_category_group_category_path(params[:id], root.id) %>
      <%= button_to_edit "Editovat kategorii", edit_admin_category_group_category_path(params[:id], root.id) %>
    </span>
  <% end %>
  
  <% unless root.children.blank? %>
  <%= content_tag :ol do %>
    <% root.children.each do |child| %>
      <%= render "categories", :root => child %>
    <% end %>
  <% end %>
  <% end %>
<% end %>